# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=totem-pl-parser
pkgver=3.26.5
pkgrel=1
pkgdesc="GNOME playlist parser library"
url="https://www.gnome.org/"
arch="all"
license="LGPL-2.0-or-later"
makedepends="meson gnome-desktop-dev libsoup-dev libxml2-dev json-glib-dev
	gmime-dev libxml2-utils libxslt itstool libarchive-dev libgcrypt-dev"
options="!check" # doesn't detect gvfs' http support
subpackages="$pkgname-dev $pkgname-lang"
source="https://download.gnome.org/sources/totem-pl-parser/${pkgver%.*}/totem-pl-parser-$pkgver.tar.xz"

build() {
	meson \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--buildtype=plain \
		-Denable-libarchive=yes \
		-Denable-libgcrypt=yes \
		-Dintrospection=true \
		build
	ninja -C build
}

check() {
	ninja -C build test
}

package() {
	DESTDIR="$pkgdir" ninja -C build install
}

sha512sums="ce110d92f60da328272a8135a57ba60785ea4bca1fde3703a734969e7ba5b382ef19dc3b8930a5641d8f8effabf627f7e9b2727ee94e69e6144e0f085079e14d  totem-pl-parser-3.26.5.tar.xz"
